$(document).ready(function(){
	$("#pitchSearchButton").click(function(event){
		if($("#studentFlag").val() == true || $("#studentFlag").val() == "true"){
			window.location.href="studentHome?searchWords=" + $("#pitchSearchTextInput").val() + 
			"&count=" + $("#countInput").val();
		}else{
			window.location.href="hfHome?searchWords=" + $("#pitchSearchTextInput").val() + 
			"&count=" + $("#countInput").val();
		}
	});
	$("#filterButton").click(function(event){
		if($("#studentFlag").val() == true || $("#studentFlag").val() == "true"){
			window.location.href="studentHome?searchWords=" + $("#currentSearchWords").val() + 
			"&count=" + $("#countSelectInput").val();
		}else{
			window.location.href="hfHome?searchWords=" + $("#currentSearchWords").val() + 
			"&count=" + $("#countSelectInput").val();
		}
	});
});